import { createRouter,  createWebHistory, RouteRecordRaw } from 'vue-router'
 
const routes: Array<RouteRecordRaw> = [
  {
    path: '/',
    name: 'Home',
    component: () => import('../pages/home/Home.vue'),
    children:[
      {
        path: '/night',
        name: 'Night',
        meta: {
          keepAlive: false 
        },
        component: () => import('../pages/care/Night.vue')
      }
    ]
  },
  {
    path: '/login',
    name: 'Login',
    meta: {
      keepAlive: false 
    },
    component: () => import('../pages/login/Login.vue')
  }
]

const router = createRouter({
  history: createWebHistory(),
  routes
})

export default router